<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>menu</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<style type="text/css">
@import "http://o.aolcdn.com/dojo/0.9.0/dijit/themes/tundra/tundra.css";
@import "http://o.aolcdn.com/dojo/0.9.0/dojo/dojo.css"
</style>
<script type="text/javascript" src="http://o.aolcdn.com/dojo/0.9.0/dojo/dojo.xd.js" djConfig="parseOnLoad: true"></script>
<script type="text/javascript">
dojo.require("dojo.parser");
dojo.require("dijit.Tree");
dojo.require("dojo.data.ItemFileReadStore");
</script>

<script type="text/javascript">
	var popStore = {};
	
	function init() {
	    var poptarts =
	        { label: 'name',
	           identifier: 'name',
	           items: [
	             { name:'Home', type:'item', url:'body.jsp'},
	             {
	             	name:'Image', type: 'category',
	             	children: [
	             		{name: 'Add', type:'item', url: 'imageEdit.do'},
	             		{name: 'List', type:'item', url: 'imageList.do'},
	             		{name: 'Map', type:'item', url: '../process/viewMap.do'},
	             		{name: 'Rebuild', type:'item', url: 'rebuild.do'}
	             	]
	             },
	             { name:'Path', type:'item', url:'repositorylist.do'}
	            ]
	        };
	    popStore = new dojo.data.ItemFileReadStore({data: poptarts});
	
	    var _tree=new dijit.Tree({           
	        id:'tree',
	        store:popStore,
	        labelAttr:"name",
	        typeAttr:"type",
	        onClick:function(item, node){
	        	if(item['type'] == 'item'){
	        		window.top.view.location = item['url'];
	        	}
	        }}, dojo.byId("tree"));
	    }
	
	dojo.addOnLoad(init);
</script>
</head>
<body class="tundra">
    <div id="tree" style="font-size: 13px;">
    </div>
</body>
</html>